<template>
    <div>
        <div class="index">
            <div class="w2" v-for="it,i in userdata" :key="i">
                <router-link to="/usercenter">
                    <div class="w2_1">
                        <img class="img1" :src="it.img" alt="">
                        <img class="img2" src="../../assets/img/v.png" alt="">
                        <div class="w2_2">
                            <span>{{it.name}}</span>
                            <span>{{it.title}}</span>
                            <span>粉丝:{{it.fans}} &nbsp;&nbsp; 获赞:{{it.Getpraise}}</span>
                        </div>
                    </div>
                    </router-link>
                <div class="plk">
                    <p>关注</p>
                </div>
            </div>
        </div>
    </div>
</template>

<script>
export default {
    data() {
        return {
            // 用户数据
            userdata: [
                {id: 1, img: 'https://img-static.mihoyo.com/communityweb/upload/6540d2dd603593cf09c6a6a32ce5be40.png', name: '布里丘丘', title: '手工作者', fans: 21221, Getpraise: 988982},
                {id: 2, img: 'https://img-static.mihoyo.com/communityweb/upload/6540d2dd603593cf09c6a6a32ce5be40.png', name: '布里丘丘', title: '手工作者', fans: 21221, Getpraise: 988982},
                {id: 3, img: 'https://img-static.mihoyo.com/communityweb/upload/6540d2dd603593cf09c6a6a32ce5be40.png', name: '布里丘丘', title: '手工作者', fans: 21221, Getpraise: 988982}
            ]
        }
    }
}
</script>

<style lang="less" scoped>
    a {
        color: #999;
        text-decoration: none;
    }
    .index {
        margin-top: 20px;
        .w2 {
                padding: 20px;
                // margin-top: 20px;
                // border: 1px solid red;
                background-color: #fff;
                display: flex;
                justify-content: space-between;
                border-bottom: 1px solid #ccc;
                border-radius: 6px;
                .w2_1 {
                    display: flex;
                    align-items: center;
                    .img1 {
                        max-width: 60px;
                        border-radius: 50%;
                        cursor: pointer;
                    }
                    .img2 {
                        // border: 1px solid red;
                        max-width: 16px;
                        border-radius: 50%;
                        margin-top: 40px;
                        margin-left: -20px;
                        cursor: pointer;
                    }
                    // img:nth-last-child(1) {
                    //     border: 1px solid red;
                    // }
                    .w2_2 {
                        // border: 1px solid red;
                        margin-left: 20px;
                        span:nth-last-child(3):hover {
                            color: #00c3ff;
                        }
                        span:nth-last-child(3) {
                            font-size: 14px;
                            display: flex;
                            flex-wrap: wrap;
                            color: #666;
                            cursor: pointer;
                        }
                        span:nth-last-child(2) {
                            font-size: 14px;
                            display: flex;
                            flex-wrap: wrap;
                            color: #999;
                            cursor: pointer;
                        }
                        span:nth-last-child(1) {
                            font-size: 14px;
                            display: flex;
                            flex-wrap: wrap;
                            color: #999;
                        }
                    }
                }
                .plk {
                    // border: 1px solid red;
                    margin-right: 30px;
                    p {
                        // border: 1px solid red;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        border-radius: 20px;
                        background-color: #00c3ff;
                        color: white;
                        height: 26px;
                        width: 60px;
                        cursor: pointer;
                        font-size: 13px;
                    }
                }
            }
    }
</style>